package com.example.demo.day.config.learn.design.adapter.x1;

//电源适配器
public class VoltAdapter implements LowVolt {

    public static final int COEFFICIENT = 44;

    private HighVolt volt;

    public VoltAdapter(HighVolt volt) {
        this.volt = volt;
    }

    @Override
    public int getFiveVolt() {
        int highVolt = volt.getVolt();
        int result = highVolt / COEFFICIENT;
        return result;
    }
}
